package com.etc.service.impl;

import com.etc.dao.OrderDao;
import com.etc.entity.Orders;
import com.etc.service.OrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class OrderServiceImpl implements OrderService {
    @Autowired
    OrderDao orderDao;

    @Override
    public Orders addOrder(Orders order) {
        return orderDao.addOrder(order);
    }

    @Override
    public List<Orders> getAllOrders() {
        return orderDao.queryAllOrders();
    }
}
